# -*- coding: utf-8 -*-

"""
@author: Rwing
@software: PyCharm
@file: views_constant.py
@time: 2021/12/2 18:10
"""

SERVER_HOST = "127.0.0.1"
SERVER_PORT = "8000"

ALL_TYPE = "0"

ORDER_TOTAL = "0"
ORDER_PRICE_UP = "1"
ORDER_PRICE_DOWN = "2"
ORDER_SALE_UP = "3"
ORDER_SALE_DOWN = "4"

ORDER_RULE_LIST = [
    ['综合排序', ORDER_TOTAL],
    ['价格升序', ORDER_PRICE_UP],
    ['价格降序', ORDER_PRICE_DOWN],
    ['销量升序', ORDER_SALE_UP],
    ['销量降序', ORDER_SALE_DOWN],
]

HTTP_STATIC_OK = 0
USER_EXIST_ALREADY = 1001  # 用户已存在状态码
EMAIL_EXIST_ALREADY = 1002  # 邮箱已存在状态码
USER_NOT_ACTIVE = 1003  # 用户未激活状态码
USER_TOKEN_EXPIRED = 1100  # 用户token已过期
USER_NOT_LOGIN = 1101  # 用户未登录
